<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        ul {
            margin: 100px;
            /* display: flex; */
        }

        ul li {
            /* float: left; */
            margin: 5px;
            width: 200px;
            height: 50px;
            list-style: none;
            perspective: 500px;
            /* background: pink; */
        }

        .box {
            position: relative;
            width: 100%;
            height: 100%;
            transform-style: preserve-3d;
            /* transform: rotateY(30deg); */
            transition: all 1s;
        }

        .box:hover {
            transform: rotateX(90deg);
        }

        .front,
        .bottom {
            position: absolute;
            width: 100%;
            height: 100%;
            font-size: 30px;
            color: #fff;
            text-align: center;
            line-height: 50px;

        }

        .front {
            background-color: pink;
            transform: translateZ(17.5px);
        }

        .bottom {
            background-color: purple;
            transform: translateY(50%) rotateX(-90deg);
        }
    </style>
</head>

<body>
    <ul>
        <li>
            <div class="box">
                <div class="front">1111</div>
                <div class="bottom">2222</div>
            </div>
        </li>
        <li>
            <div class="box">
                <div class="front">1111</div>
                <div class="bottom">2222</div>
            </div>
        </li>
        <li>
            <div class="box">
                <div class="front">1111</div>
                <div class="bottom">2222</div>
            </div>
        </li>
        <li>
            <div class="box">
                <div class="front">1111</div>
                <div class="bottom">2222</div>
            </div>
        </li>
        <li>
            <div class="box">
                <div class="front">1111</div>
                <div class="bottom">2222</div>
            </div>
        </li>
        <li>
            <div class="box">
                <div class="front">1111</div>
                <div class="bottom">2222</div>
            </div>
        </li>
        <li>
            <div class="box">
                <div class="front">1111</div>
                <div class="bottom">2222</div>
            </div>
        </li>
    </ul>
</body>

</html>